<div class="dsn-panel-editor-title">秒杀商品设置</div>
<div class="dsn-panel-editor-content">
	<div class="layui-form-item">
		<div class="layui-form-label">与上方距离</div>
		<div class="slider" min="0" max="40" ng-model="Edit.params.margin_y"></div>
		<span class="slider-span"><input ng-model="Edit.params.margin_y"/> px</span>
	</div>

	<div class="layui-form-item">
		<div class="layui-form-label">商品风格</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_shopstyle" value="1" ng-model="Edit.params.shopstyle" title="风格一"/>
			<input class="radio" type="radio" name="{{Edit.id}}_shopstyle" value="2" ng-model="Edit.params.shopstyle" title="风格二"/>
		</div>
	</div>

	<div ng-show="Edit.params.shopstyle=='2'" class="layui-form-item">
		<div class="layui-form-label">标题倒计时</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_showtitle" value="1" ng-model="Edit.params.showtitle" title="显示"/>
			<input class="radio" type="radio" name="{{Edit.id}}_showtitle" value="0" ng-model="Edit.params.showtitle" title="不显示"/>
		</div>
	</div>
	<div ng-show="Edit.params.shopstyle=='2'" class="layui-form-item">
		<div class="layui-form-label">标题风格</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_titlestyle" value="1" ng-model="Edit.params.titlestyle" title="风格一"/>
			<input class="radio" type="radio" name="{{Edit.id}}_titlestyle" value="2" ng-model="Edit.params.titlestyle" title="风格二"/>
		</div>
	</div>

	<div ng-if="Edit.params.shopstyle=='1' || !Edit.params.shopstyle" class="layui-form-item">
		<div class="layui-form-label">样式选择</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_style" value="1" ng-model="Edit.params.style" ng-change="changeImg(Edit.id, Edit.params.style)" title="单排"/>
			<input class="radio" type="radio" name="{{Edit.id}}_style" value="2" ng-model="Edit.params.style" ng-change="changeImg(Edit.id, Edit.params.style)" title="双排"/>
			<input class="radio" type="radio" name="{{Edit.id}}_style" value="3" ng-model="Edit.params.style" ng-change="changeImg(Edit.id, Edit.params.style)" title="三排"/>
			<input class="radio" type="radio" name="{{Edit.id}}_style" value="list" ng-model="Edit.params.style" ng-change="changeImg(Edit.id, Edit.params.style)" title="横排"/>
			<input class="radio" type="radio" name="{{Edit.id}}_style" value="line" ng-model="Edit.params.style" ng-change="changeImg(Edit.id, Edit.params.style)" title="左右滑动"/>
		</div>
	</div>

	<div ng-if="Edit.params.shopstyle=='2'" class="layui-form-item">
		<div class="layui-form-label">样式选择</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_style" value="2" ng-model="Edit.params.style" ng-change="changeImg(Edit.id, Edit.params.style)" title="双排"/>
			<input class="radio" type="radio" name="{{Edit.id}}_style" value="list" ng-model="Edit.params.style" ng-change="changeImg(Edit.id, Edit.params.style)" title="横排"/>
			<input class="radio" type="radio" name="{{Edit.id}}_style" value="line" ng-model="Edit.params.style" ng-change="changeImg(Edit.id, Edit.params.style)" title="左右滑动"/>
		</div>
	</div>

	<div class="layui-form-item">
		<div class="layui-form-label">商品名称</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_showname" value="1" ng-model="Edit.params.showname" title="显示"/>
			<input class="radio" type="radio" name="{{Edit.id}}_showname" value="0" ng-model="Edit.params.showname" title="不显示"/>
		</div>
	</div>
	<div class="layui-form-item">
		<div class="layui-form-label">商品价格</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_showprice" value="1" ng-model="Edit.params.showprice" title="原价+秒杀价"/>
			<input class="radio" type="radio" name="{{Edit.id}}_showprice" value="2" ng-model="Edit.params.showprice" title="只显示秒杀价"/>
			<input class="radio" type="radio" name="{{Edit.id}}_showprice" value="0" ng-model="Edit.params.showprice" title="不显示"/>
		</div>
	</div>
	<div class="layui-form-item">
		<div class="layui-form-label">商品销量</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_showsales" value="0" ng-model="Edit.params.showsales" title="不显示"/>
			<input class="radio" type="radio" name="{{Edit.id}}_showsales" value="1" ng-model="Edit.params.showsales" title="显示"/>
		</div>
		<span class="layui-form-mid layui-word-aux">提示：显示销量时，销量大于0才会显示</span>
	</div>
	<div ng-if="Edit.params.shopstyle=='1' || !Edit.params.shopstyle" class="layui-form-item">
		<div class="layui-form-label">倒计时</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_showtime" value="1" ng-model="Edit.params.showtime" title="显示"/>
			<input class="radio" type="radio" name="{{Edit.id}}_showtime" value="0" ng-model="Edit.params.showtime" title="不显示"/>
		</div>
		<span class="layui-form-mid layui-word-aux">根据时间显示文字：距开抢xx；距结束xx;已结束;(三排和左右滑动不显示时间)</span>
	</div>
	<div class="layui-form-item">
		<div class="layui-form-label">商品属性</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="radio" type="radio" name="{{Edit.id}}_saleimg" value="" ng-model="Edit.params.saleimg" title="无"/>
			<input class="radio" type="radio" name="{{Edit.id}}_saleimg" value="{:getCurUrl()}/static/imgsrc/sale-tj.png" ng-model="Edit.params.saleimg" title="推荐"/>
			<input class="radio" type="radio" name="{{Edit.id}}_saleimg" value="{:getCurUrl()}/static/imgsrc/sale-rx.png" ng-model="Edit.params.saleimg" title="热销"/>
			<input class="radio" type="radio" name="{{Edit.id}}_saleimg" value="{:getCurUrl()}/static/imgsrc/sale-xp.png" ng-model="Edit.params.saleimg" title="新上"/>
			<input class="radio" type="radio" name="{{Edit.id}}_saleimg" value="{:getCurUrl()}/static/imgsrc/sale-xs.png" ng-model="Edit.params.saleimg" title="限时"/>
			<input class="radio" type="radio" name="{{Edit.id}}_saleimg" value="{:getCurUrl()}/static/imgsrc/sale-cx.png" ng-model="Edit.params.saleimg" title="促销"/>
			<span class="dsn-panel-editor-btn" ng-click="uploadImg(Edit.id,'saleimg')">自己上传</span>
		</div>
	</div>
	<div class="layui-form-item">
		<div class="layui-form-label">背景颜色</div>
		<div class="layui-input-inline">
			<input class="layui-input" value="{{Edit.params.bgcolor}}" ng-model="Edit.params.bgcolor"/>
		</div>
		<span class="colorpicker" ng-model="Edit.params.bgcolor"></span>
	</div>

	<div class="layui-form-item">
		<div class="layui-form-label">商品来源</div>
		<div class="layui-input-inline" style="width:500px">
			{if !$type}
			<input class="radio" type="radio" name="{{Edit.id}}_productfrom" value="0" ng-model="Edit.params.productfrom" title="手动选择"/>
			{/if}
			<input class="radio" type="radio" name="{{Edit.id}}_productfrom" value="1" ng-model="Edit.params.productfrom" title="分组分类" ng-change="getseckill(Edit.id)"/>
		</div>
	</div>
	<div ng-show="Edit.params.productfrom == '0'">
		<div ng-repeat="good in Edit.data" class="dsn-panel-editor-relative">
			<div class="dsn-panel-editor-del" style="right:30px;font-size:12px" title="上移" ng-click="upItemChild(Edit.id,good.id)"><i class="fa fa-arrow-up"></i></div>
			<div class="dsn-panel-editor-del" title="移除" ng-click="delseckill(Edit.id,good.id)">×</div>
			<div class="dsn-panel-editor-line flex">
				<div class="dsn-panel-editor-goodimg flex0" ng-click="addseckill('replace',Edit.id, good.id)">
					<img ng-src="{{good.pic}}" width="100%"/>
					<div class="dsn-panel-editor-goodimg-t2">重新选择商品</div>
				</div>
				<div class="dsn-panel-editor-line-right">
					<div class="layui-form-item">
						<div class="layui-form-label">商品名称</div>
						<div class="layui-form-mid">{{good.name}}</div>
					</div>
					<div class="layui-form-item">
						<div class="layui-form-label">商品价格</div>
						<div class="layui-form-mid"><span style="font-size: 16px;">￥{{good.sell_price}}</span> <span style="text-decoration: line-through;">￥{{good.market_price}}</span></div>
					</div>
				</div>
			</div>
		</div>
		<div class="layui-btn layui-btn-primary" style="width:500px;margin-top:10px" ng-click="addseckill('',Edit.id,'')"><i class="fa fa-plus-circle"></i> 添加一个商品</div>
	</div>
	<div ng-show="Edit.params.productfrom == '1'">
		{if $bid==0}
		<div class="layui-form-item">
			<div class="layui-form-label">所属商家</div>
			<div class="layui-input-inline">
				<select class="layui-input" style="width:200px;-webkit-appearance:menulist" lay-ignore ng-model="Edit.params.bid" ng-change="getseckill(Edit.id)">
					<option value="0">自营</option>
					<option value="">全部</option>
					{if !$type}
						{foreach $bnlist as $bv}
							<option value="{$bv['id']}">{$bv['name']}</option>
						{/foreach}
					{/if}
				</select>
			</div>
		</div>
		{/if}

		<div class="layui-form-item">
			<div class="layui-form-label">排序方式</div>
			<div class="layui-input-inline" style="width:500px">
				<input class="radio" type="radio" name="{{Edit.id}}_sortby" value="sort" ng-model="Edit.params.sortby" ng-change="getseckill(Edit.id)" title="按排序"/>
				<input class="radio" type="radio" name="{{Edit.id}}_sortby" value="createtimedesc" ng-model="Edit.params.sortby" ng-change="getseckill(Edit.id)" title="创建时间↓"/></i>
				<input class="radio" type="radio" name="{{Edit.id}}_sortby" value="createtime" ng-model="Edit.params.sortby" ng-change="getseckill(Edit.id)" title="创建时间↑"/></i>
				<input class="radio" type="radio" name="{{Edit.id}}_sortby" value="sales" ng-model="Edit.params.sortby" ng-change="getseckill(Edit.id)" title="销量"/>
			</div>
		</div>
		<div class="layui-form-item">
			<div class="layui-form-label">显示数量</div>
			<div class="layui-input-inline">
				<input class="layui-input" ng-model="Edit.params.proshownum" ng-blur="getseckill(Edit.id)"/>
			</div>
		</div>
	</div>
	<hr>
	<div class="layui-form-item">
		<div class="layui-form-label">左右边距</div>
		<div class="slider" min="0" max="40" ng-model="Edit.params.margin_x"></div>
		<span class="slider-span"><input ng-model="Edit.params.margin_x"/> px</span>
	</div>
	<div class="layui-form-item">
		<div class="layui-form-label">左右内边距</div>
		<div class="slider" min="0" max="40" ng-model="Edit.params.padding_x"></div>
		<span class="slider-span"><input ng-model="Edit.params.padding_x"/> px</span>
	</div>
	<div class="layui-form-item">
		<div class="layui-form-label">上下内边距</div>
		<div class="slider" min="0" max="40" ng-model="Edit.params.padding_y"></div>
		<span class="slider-span"><input ng-model="Edit.params.padding_y"/> px</span>
	</div>
	{if !$type}
	<div class="layui-form-item">
		<div class="layui-form-label">显示平台</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="checkbox" type="checkbox" lay-skin="primary" title="所有平台" name="{{Edit.id}}_platform['all']" ng-model="Edit.params.platform['all']"/>
			{foreach $platform as $pl}
			<input class="checkbox" type="checkbox" lay-skin="primary" title="{:getplatformname($pl)}" name="{{Edit.id}}_platform['{$pl}']" ng-model="Edit.params.platform['{$pl}']"/>
			{/foreach}
		</div>
	</div>
	<div class="layui-form-item">
		<div class="layui-form-label">显示范围</div>
		<div class="layui-input-inline" style="width:500px">
			<input class="checkbox" type="checkbox" lay-skin="primary" title="所有人" name="{{Edit.id}}_quanxian['all']" ng-model="Edit.params.quanxian['all']"/>
			{foreach $memberlevelList as $lv}
			<input class="checkbox" type="checkbox" lay-skin="primary" title="{$lv.name}" name="{{Edit.id}}_quanxian[{$lv.id}]" ng-model="Edit.params.quanxian[{$lv.id}]"/>
			{/foreach}
		</div>
	</div>
	<div class="layui-form-item" ng-show="!Edit.params.quanxian['all']">
    <div class="layui-form-label">显示用户</div>
    <div class="layui-input-inline">
			<input class="layui-input" ng-model="Edit.params.showmids"/>
    </div>
		<div class="layui-form-mid layui-word-aux">填写用户ID，多个用英文标点逗号(,)分割
	</div>
	{else}
        <input class="checkbox" type="hidden" checked='true' lay-skin="primary" title="所有平台" name="{{Edit.id}}_platform['all']" ng-model="Edit.params.platform['all']"/>
        <input class="checkbox" type="hidden" checked='true' lay-skin="primary" title="所有人" name="{{Edit.id}}_quanxian['all']" ng-model="Edit.params.quanxian['all']"/>
        <input class="checkbox" type="hidden" checked='true' lay-skin="primary" title="所有门店" name="{{Edit.id}}_mendian['all']" ng-model="Edit.params.mendian['all']"/>
    {/if}
</div>